{smcl}
{com}{sf}{ul off}{txt}{.-}
      name:  {res}<unnamed>
       {txt}log:  {res}C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\outputs\logs\figures4and5.smcl
  {txt}log type:  {res}smcl
 {txt}opened on:  {res}19 May 2024, 20:28:39
{txt}
{com}. 
. /***************************** Flood to CP/LEPA *******************************/
. /* Import the flood to cp or lepa event study coefficients */
.         *Start with TWFE
.         import excel using "$dr_temp\twfe_event_study.xlsx", firstrow sheet(floodtocplepa_91_15_nyt) clear
{res}{text}(7 vars, 144 obs)

{com}.         gen estimator = "twfe"
{txt}
{com}.         gen scaled_estimate = 100*estimate/panel_mean_dep_var
{txt}
{com}.         rename (ci_low_95 ci_high_95) (lb_estimate ub_estimate)
{res}{txt}
{com}.         gen scaled_lb = 100*lb_estimate/panel_mean_dep_var
{txt}
{com}.         gen scaled_ub = 100*ub_estimate/panel_mean_dep_var
{txt}
{com}.         keep dep_var estimator effect_estimated scaled_estimate scaled_lb scaled_ub estimate lb_estimate ub_estimate
{txt}
{com}.         save "${c -(}dr_temp{c )-}\floodtocplepa_es_twfe.dta", replace
{txt}{p 0 4 2}
file {bf}
C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\data\intermediate\floodtocplepa_es_twfe.dta{rm}
saved
{p_end}

{com}. 
.         *Now do CS
.         import excel "${c -(}dr_temp{c )-}/cs_floodtocporlepa_91_15_nyt.xlsx", firstrow sheet(cs_event) clear
{res}{text}(8 vars, 141 obs)

{com}.         gen estimator = "c&s"
{txt}
{com}.         foreach var of varlist effect_estimated estimate se_estimate c_crit_val panel_mean_dep_var {c -(}
{txt}  2{com}.                 destring `var', replace
{txt}  3{com}.         {c )-}
{txt}effect_estimated: all characters numeric; {res}replaced {txt}as {res}byte
{txt}estimate: all characters numeric; {res}replaced {txt}as {res}double
{txt}se_estimate: all characters numeric; {res}replaced {txt}as {res}double
{txt}c_crit_val: all characters numeric; {res}replaced {txt}as {res}double
{txt}panel_mean_dep_var: all characters numeric; {res}replaced {txt}as {res}double
{txt}
{com}.         gen scaled_estimate = 100*estimate/panel_mean_dep_var
{txt}
{com}.         rename (ci_95_lb ci_95_ub) (lb_estimate ub_estimate)
{res}{txt}
{com}.         gen scaled_lb = 100*lb_estimate/panel_mean_dep_var
{txt}
{com}.         gen scaled_ub = 100*ub_estimate/panel_mean_dep_var
{txt}
{com}.         keep dep_var estimator effect_estimated scaled_estimate scaled_lb scaled_ub estimate lb_estimate ub_estimate
{txt}
{com}.         save "${c -(}dr_temp{c )-}\floodtocplepa_es_cs.dta", replace
{txt}{p 0 4 2}
file {bf}
C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\data\intermediate\floodtocplepa_es_cs.dta{rm}
saved
{p_end}

{com}. 
.         *Append the TWFE results 
.         append using "${c -(}dr_temp{c )-}\floodtocplepa_es_twfe.dta"
{txt}{p 0 7 2}
(variable
{bf:estimator} was {bf:str3}, now {bf:str4} to accommodate using data's values)
{p_end}

{com}.         
.         *Generate column indicating tech transition and save
.         gen transition = "flood_to_cp"
{txt}
{com}.         save "${c -(}dr_temp{c )-}\floodtocplepa_es_twfecs.dta", replace 
{txt}{p 0 4 2}
file {bf}
C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\data\intermediate\floodtocplepa_es_twfecs.dta{rm}
saved
{p_end}

{com}.  
. ********************************************************************************
. /* Figure 4 - Plot dynamic treatment effect estimates for flood to center-pivot
> or LEPA conversion in percent terms for TWFE and CS estimators */
. ********************************************************************************
. *Sort 
. sort dep_var effect_estimated
{txt}
{com}. 
. *Now offset the location of scaled_estimates for C&S so they don't overlap
. replace effect_estimated = effect_estimated + 0.5 if estimator=="c&s"
{txt}variable {bf}{res}effect_estimated{sf}{txt} was {bf}{res}byte{sf}{txt} now {bf}{res}float{sf}
{txt}(141 real changes made)

{com}. 
. *Replace extreme ub and lb estimates with -50 and +50 to make graphs readable 
. gen extreme = scaled_ub > 40 | scaled_lb < -40
{txt}
{com}. replace scaled_ub = 40 if scaled_ub > 40
{txt}(14 real changes made)

{com}. replace scaled_lb = -40 if scaled_lb < -40
{txt}(7 real changes made)

{com}. 
. /* Graph C&S, C&D, and TWFE together */
. *AF_USED_IRR
.         tw      (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & dep_var=="af_used" & extreme!=1, msize(.3) lwidth(.1) lcolor(orange%75)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="twfe" & dep_var=="af_used", lwidth(.1) lcolor(orange%75) msize(.4) mcolor(orange%75)  msymbol(T)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & extreme==1 & dep_var=="af_used",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(orange%75)) /// 
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & dep_var=="af_used" & extreme!=1,  msize(.3) lwidth(.1) lcolor(blue%100)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="c&s" & dep_var=="af_used", lwidth(.1) lcolor(blue%100) msize(.4) mcolor(blue%100) msymbol(O)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & extreme==1 & dep_var=="af_used",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(blue%100)), /// 
>                         title("        Flood to center pivot", size(small)) ///
>                         subtitle("Acre-feet withdrawn", size(small)) ///
>                         xtitle("Time relative to adoption (years)", size(vsmall)) ///
>                         yline(0, lpattern(solid)) ///
>                         ytitle("Percent change", size(small)) ///
>                         ylab(-40(20)40, ang(45) nogrid) ///
>                         xlab(-24 -20(5)20 23, nogrid) ///
>                         xscale(range(-24 24)) ///
>                         legend(order(5 2) label(5 "{c -(}it:{c -(}&delta{c )-}{c -(}superscript:CS{c )-}(l){c )-} from Callaway & Sant'Anna (2020)") ///
>                                                           label(2 "{c -(}it:{c -(}&beta{c )-}{c -(}superscript:TWFE{c )-}(l){c )-} TWFE event study")  ///
>                                                                 cols(1) size(vsmall)) ///
>                         graphregion(color(white) margin(zero)) name(es_af_used, replace)
{res}{txt}
{com}. 
. *ACRES_IRR
.         tw      (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & dep_var=="acres_irr" & extreme!=1, msize(.3) lwidth(.1) lcolor(orange%75)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="twfe" & dep_var=="acres_irr", lwidth(.1) lcolor(orange%75) msize(.4) mcolor(orange%75)  msymbol(T)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & extreme==1 & dep_var=="acres_irr",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(orange%75)) /// 
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & dep_var=="acres_irr" & extreme!=1,  msize(.3) lwidth(.1) lcolor(blue%100)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="c&s" & dep_var=="acres_irr", lwidth(.1) lcolor(blue%100) msize(.4) mcolor(blue%100)  msymbol(O)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & extreme==1 & dep_var=="acres_irr",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(blue%100)), /// 
>                         title("        Flood to center pivot", size(small)) ///
>                         subtitle("Acres irrigated", size(small)) ///
>                         xtitle("Time relative to adoption (years)", size(vsmall)) ///
>                         yline(0, lpattern(solid)) ///
>                         ytitle("Percent change", size(small)) ///
>                         ylab(-40(20)40, ang(45) nogrid) ///
>                         xlab(-24 -20(5)20 23, nogrid) ///
>                         xscale(range(-24 24)) ///
>                         legend(order(5 2) label(5 "{c -(}it:{c -(}&delta{c )-}{c -(}superscript:CS{c )-}(l){c )-} from Callaway & Sant'Anna (2020)") ///
>                                                             label(2 "{c -(}it:{c -(}&beta{c )-}{c -(}superscript:TWFE{c )-}(l){c )-} TWFE event study")  ///
>                                                                 cols(1) size(vsmall)) ///
>                                                                 graphregion(color(white) margin(zero)) name(es_acres_irr, replace)
{res}{txt}
{com}. 
. *DEPTH APPLIED
.         tw      (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & dep_var=="depth_applied" & extreme!=1, msize(.3) lwidth(.1) lcolor(orange%75)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="twfe" & dep_var=="depth_applied", lwidth(.1) lcolor(orange%75) msize(.4) mcolor(orange%75) msymbol(T)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & extreme==1 & dep_var=="depth_applied",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(orange%75)) /// 
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & dep_var=="depth_applied" & extreme!=1,  msize(.3) lwidth(.1) lcolor(blue%100)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="c&s" & dep_var=="depth_applied", lwidth(.1) lcolor(blue%100) msize(.4) mcolor(blue%100) msymbol(O)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & extreme==1 & dep_var=="depth_applied",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(blue%100)), /// 
>                         title("        Flood to center pivot", size(small)) ///
>                         subtitle("Depth applied", size(small)) ///
>                         xtitle("Time relative to adoption (years)", size(vsmall)) ///
>                         yline(0, lpattern(solid)) ///
>                         ytitle("Percent change", size(small)) ///
>                         ylab(-40(20)40, ang(45) nogrid) ///
>                         xlab(-24 -20(5)20 23, nogrid) ///
>                         xscale(range(-24 24)) ///
>                         legend(order(5 2) label(5 "{c -(}it:{c -(}&delta{c )-}{c -(}superscript:CS{c )-}(l){c )-} from Callaway & Sant'Anna (2020)") ///
>                                                           label(2 "{c -(}it:{c -(}&beta{c )-}{c -(}superscript:TWFE{c )-}(l){c )-} TWFE event study")  ///
>                                                                 cols(1) size(vsmall)) ///
>                                                                 graphregion(color(white) margin(zero)) name(es_depth_applied, replace)
{res}{txt}
{com}.                         
. /* Combine the graphs */
. grc1leg2 es_af_used es_acres_irr es_depth_applied, ///
>         rows(3) cols(1) legendfrom(es_af_used) ///
>         maintotoptitle maintitlefrom(es_af_used) ///
>         xtob1title xtitlefrom(es_af_used) ///
>         ytol1title ytitlefrom(es_af_used) ///
>         labsize(vsmall) graphregion(color(white)) xsize(6.5) ysize(8) iscale(.8) ring(1)
{txt}-grc1leg2- working...
{res}{txt}Warning: Because the legend borrowed for the combined graph is not "complete",
automatic resizing of legend markers is disabled and {cmd:grc1leg2} ignores the option -lmsize-.
See the discussion of "known issues" in {cmd:grc1leg2}'s help file {help grc1leg2##known:here}.

{com}. graph export "$dr_output_main\figure4.tif", width(9750) height(11850) replace
{txt}{p 0 4 2}
file {bf}
C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\outputs\main_text\figure4.tif{rm}
saved as
TIFF
format
{p_end}

{com}. 
. /***************************** CP to LEPA *******************************/                      
. /* Import the cp to lepa event study coefficients */
.         *Start with TWFE
.         import excel using "$dr_temp\twfe_event_study.xlsx", firstrow sheet(cptolepa_91_19) clear
{res}{text}(7 vars, 168 obs)

{com}.         gen estimator = "twfe"
{txt}
{com}.         gen scaled_estimate = 100*estimate/panel_mean_dep_var
{txt}
{com}.         rename (ci_low_95 ci_high_95) (lb_estimate ub_estimate)
{res}{txt}
{com}.         gen scaled_lb = 100*lb_estimate/panel_mean_dep_var
{txt}
{com}.         gen scaled_ub = 100*ub_estimate/panel_mean_dep_var
{txt}
{com}.         keep dep_var estimator effect_estimated scaled_estimate scaled_lb scaled_ub estimate lb_estimate ub_estimate
{txt}
{com}.         save "${c -(}dr_temp{c )-}\cptolepa_es_twfe.dta", replace
{txt}{p 0 4 2}
file {bf}
C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\data\intermediate\cptolepa_es_twfe.dta{rm}
saved
{p_end}

{com}. 
.         *Now do CS
.         import excel "${c -(}dr_temp{c )-}/cs_cptolepa.xlsx", firstrow sheet(cs_event) clear
{res}{text}(8 vars, 165 obs)

{com}.         gen estimator = "c&s"
{txt}
{com}.         foreach var of varlist effect_estimated estimate se_estimate c_crit_val panel_mean_dep_var {c -(}
{txt}  2{com}.                 destring `var', replace
{txt}  3{com}.         {c )-}
{txt}effect_estimated: all characters numeric; {res}replaced {txt}as {res}byte
{txt}estimate: all characters numeric; {res}replaced {txt}as {res}double
{txt}se_estimate: all characters numeric; {res}replaced {txt}as {res}double
{txt}c_crit_val: all characters numeric; {res}replaced {txt}as {res}double
{txt}panel_mean_dep_var: all characters numeric; {res}replaced {txt}as {res}double
{txt}
{com}.         gen scaled_estimate = 100*estimate/panel_mean_dep_var
{txt}
{com}.         rename (ci_95_lb ci_95_ub) (lb_estimate ub_estimate)
{res}{txt}
{com}.         gen scaled_lb = 100*lb_estimate/panel_mean_dep_var
{txt}
{com}.         gen scaled_ub = 100*ub_estimate/panel_mean_dep_var
{txt}
{com}.         keep dep_var estimator effect_estimated scaled_estimate scaled_lb scaled_ub estimate lb_estimate ub_estimate
{txt}
{com}.         save "${c -(}dr_temp{c )-}\cptolepa_es_cs.dta", replace
{txt}{p 0 4 2}
file {bf}
C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\data\intermediate\cptolepa_es_cs.dta{rm}
saved
{p_end}

{com}. 
.         *Append the TWFE  results 
.         append using "${c -(}dr_temp{c )-}\cptolepa_es_twfe.dta"  
{txt}{p 0 7 2}
(variable
{bf:estimator} was {bf:str3}, now {bf:str4} to accommodate using data's values)
{p_end}

{com}.                 
.         *Generate column indicating tech transition and save
.         gen transition = "cp_to_lepa"
{txt}
{com}.         save "${c -(}dr_temp{c )-}\cptolepa_es_twfecs.dta", replace 
{txt}{p 0 4 2}
file {bf}
C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\data\intermediate\cptolepa_es_twfecs.dta{rm}
saved
{p_end}

{com}. 
. ********************************************************************************
. /* Figure 5 - Plot dynamic treatment effect estimates for center-pivot to LEPA
> conversion in percent terms for TWFE and CS estimators */
. ********************************************************************************
. *Sort 
. sort dep_var effect_estimated
{txt}
{com}. 
. *Now offset the location of scaled_estimates for C&S so they don't overlap
. replace effect_estimated = effect_estimated + 0.5 if estimator=="c&s"
{txt}variable {bf}{res}effect_estimated{sf}{txt} was {bf}{res}byte{sf}{txt} now {bf}{res}float{sf}
{txt}(165 real changes made)

{com}. 
. *Replace extreme ub and lb estimates with -50 and +50 to make graphs readable 
. gen extreme = scaled_ub > 40 | scaled_lb < -40
{txt}
{com}. replace scaled_ub = 40 if scaled_ub > 40
{txt}(1 real change made)

{com}. replace scaled_lb = -40 if scaled_lb < -40
{txt}(9 real changes made)

{com}. 
. /* Graph C&S together with C&D */
. *AF_USED_IRR
.         tw      (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & dep_var=="af_used" & extreme!=1, msize(.3) lwidth(.1) lcolor(orange%75)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="twfe" & dep_var=="af_used", lwidth(.1) lcolor(orange%75) msize(.4) mcolor(orange%75)  msymbol(T)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & extreme==1 & dep_var=="af_used",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(orange%75)) /// 
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & dep_var=="af_used" & extreme!=1,  msize(.3) lwidth(.1) lcolor(blue%100)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="c&s" & dep_var=="af_used", lwidth(.1) lcolor(blue%100) msize(.4) mcolor(blue%100) msymbol(O)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & extreme==1 & dep_var=="af_used",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(blue%100)), /// 
>                         title("        Traditional center pivot to LEPA", size(small)) ///
>                         subtitle("Acre-feet withdrawn", size(small)) ///
>                         xtitle("Time relative to adoption (years)", size(vsmall)) ///
>                         yline(0, lpattern(solid)) ///
>                         ytitle("Percent change", size(small)) ///
>                         ylab(-40(20)40, ang(45) nogrid) ///
>                         xlab(-28 -20(5)20 27,  nogrid) ///
>                         xscale(range(-28.5 27.5)) ///
>                         legend(order(8 5 2) label(5 "{c -(}it:{c -(}&delta{c )-}{c -(}superscript:CS{c )-}(l){c )-} from Callaway & Sant'Anna (2020)") ///
>                                                           label(2 "{c -(}it:{c -(}&beta{c )-}{c -(}superscript:TWFE{c )-}(l){c )-} TWFE event study")  ///
>                                                                 cols(1) size(vsmall)) ///
>                         graphregion(color(white) margin(zero)) name(es_af_used, replace)
{res}{txt}
{com}. 
. *ACRES_IRR
.         tw      (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & dep_var=="acres_irr" & extreme!=1, msize(.3) lwidth(.1) lcolor(orange%75)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="twfe" & dep_var=="acres_irr", lwidth(.1) lcolor(orange%75) msize(.4) mcolor(orange%75)  msymbol(T)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & extreme==1 & dep_var=="acres_irr",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(orange%75)) /// 
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & dep_var=="acres_irr" & extreme!=1,  msize(.3) lwidth(.1) lcolor(blue%100)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="c&s" & dep_var=="acres_irr", lwidth(.1) lcolor(blue%100) msize(.4) mcolor(blue%100) msymbol(O)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & extreme==1 & dep_var=="acres_irr",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(blue%100)), /// 
>                         title("        Traditional center pivot to LEPA", size(small)) ///
>                         subtitle("Acres irrigated", size(small)) ///
>                         xtitle("Time relative to adoption (years)", size(vsmall)) ///
>                         yline(0, lpattern(solid)) ///
>                         ytitle("Percent change", size(small)) ///
>                         ylab(-40(20)40, ang(45) nogrid) ///
>                         xlab(-28 -20(5)20 27,  nogrid) ///
>                         xscale(range(-24 24)) ///
>                         legend(order(8 5 2) label(5 "{c -(}it:{c -(}&delta{c )-}{c -(}superscript:CS{c )-}(l){c )-} from Callaway & Sant'Anna (2020)") ///
>                                                           label(2 "{c -(}it:{c -(}&beta{c )-}{c -(}superscript:TWFE{c )-}(l){c )-} TWFE event study")  ///
>                                                                 cols(1) size(vsmall)) ///
>                                                                 graphregion(color(white) margin(zero)) name(es_acres_irr, replace)
{res}{txt}
{com}. 
. *DEPTH APPLIED
.         tw      (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & dep_var=="depth_applied" & extreme!=1, msize(.3) lwidth(.1) lcolor(orange%75)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="twfe" & dep_var=="depth_applied", lwidth(.1) lcolor(orange%75) msize(.4) mcolor(orange%75)  msymbol(T)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="twfe" & extreme==1 & dep_var=="depth_applied",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(orange%75)) /// 
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & dep_var=="depth_applied" & extreme!=1,  msize(.3) lwidth(.1) lcolor(blue%100)) /// 
>                 (connected scaled_estimate effect_estimated if estimator=="c&s" & dep_var=="depth_applied", lwidth(.1) lcolor(blue%100) msize(.4) mcolor(blue%100) msymbol(O)) ///
>                 (rcap scaled_ub scaled_lb effect_estimated if estimator=="c&s" & extreme==1 & dep_var=="depth_applied",  msize(0) lpattern("shortdash") lwidth(.1) lcolor(blue%100)), /// 
>                         title("        Traditional center pivot to LEPA", size(small)) ///
>                         subtitle("Depth applied", size(small)) ///
>                         xtitle("Time relative to adoption (years)", size(vsmall)) ///
>                         yline(0, lpattern(solid)) ///
>                         ytitle("Percent change", size(small)) ///
>                         ylab(-40(20)40, ang(45) nogrid) ///
>                         xlab(-28 -20(5)20 27,  nogrid) ///
>                         xscale(range(-24 24)) ///
>                         legend(order(8 5 2) label(5 "{c -(}it:{c -(}&delta{c )-}{c -(}superscript:CS{c )-}(l){c )-} from Callaway & Sant'Anna (2020)") ///
>                                                           label(2 "{c -(}it:{c -(}&beta{c )-}{c -(}superscript:TWFE{c )-}(l){c )-} TWFE event study")  ///
>                                                                 cols(1) size(vsmall)) ///
>                                                                 graphregion(color(white) margin(zero)) name(es_depth_applied, replace)
{res}{txt}
{com}.                         
. /* Combine the graphs */
. grc1leg2 es_af_used es_acres_irr es_depth_applied, ///
>         rows(3) cols(1) legendfrom(es_af_used) ///
>         maintotoptitle maintitlefrom(es_af_used) ///
>         xtob1title xtitlefrom(es_af_used) ///
>         ytol1title ytitlefrom(es_af_used) ///
>         labsize(vsmall) graphregion(color(white)) xsize(6.5) ysize(8) iscale(.8) ring(1)
{txt}-grc1leg2- working...
{res}{txt}Warning: Because the legend borrowed for the combined graph is not "complete",
automatic resizing of legend markers is disabled and {cmd:grc1leg2} ignores the option -lmsize-.
See the discussion of "known issues" in {cmd:grc1leg2}'s help file {help grc1leg2##known:here}.

{com}. graph export "${c -(}dr_output_main{c )-}\figure5.tif", width(9750) height(11850) replace
{txt}{p 0 4 2}
file {bf}
C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\outputs\main_text\figure5.tif{rm}
saved as
TIFF
format
{p_end}

{com}. 
. *Close log
. log close
      {txt}name:  {res}<unnamed>
       {txt}log:  {res}C:\Users\Micah\Dropbox\Irrigation technology transition\final revisions for conditional acceptance\replication materials\outputs\logs\figures4and5.smcl
  {txt}log type:  {res}smcl
 {txt}closed on:  {res}19 May 2024, 20:29:47
{txt}{.-}
{smcl}
{txt}{sf}{ul off}